<include file="Weixin/header" />
<title>{$roominfo['doornumber']}</title>
<script type="text/javascript" src="__PUBLIC__/weixin/js/jquery.touchSlider.js"></script>
</head>
<body class="clearfix home">
    <div class="head">
        <div class="banner">
            <div class="img_gallery">
                <div class="point">
                    <a href="#">1</a>
                    <a href="#">2</a>
                </div>
                <div class="main_img">
                    <ul>
                        <li><span class="img_1"></span></li>
                        <li><span class="img_2"></span></li>
                    </ul>
                    <a href="javascript:;" id="btn_prev"></a>
                    <a href="javascript:;" id="btn_next"></a>
                </div>
            </div>
        </div>
        <div class="tex">
            <h3>￥{$roominfo['rent']}/月 </h3>
        </div>
    </div>
    <div class="msg">
        <h3>户型介绍</h3>
        <p>{$roominfo['desc']}</p>
    </div>
 
    <div class="pt clearfix" style="margin-bottom: 2rem;">
        <h3>房间配置</h3>
        <ul>
            <li><img src="__PUBLIC__/weixin/images/j1.png"> <br> WiFi</li>
            <li><img src="__PUBLIC__/weixin/images/j2.png"><br>电视</li>
            <li><img src="__PUBLIC__/weixin/images/j3.png"><br>洗衣机</li>
            <li><img src="__PUBLIC__/weixin/images/j4.png"><br>冰箱</li>
        </ul>
        <div class="pd">前置排队人数：10人</div>
    </div>
    
    <div class="botbtnbg">
        <a href="rental.html?roomid={$roominfo['roomid']}"><div class="btn btn1">立即租房</div></a>
        <a href="yuyue.html?roomid={$roominfo['roomid']}"><div class="btn btn2">预约看房</div></a>
    </div>
    <script>
       $dragBln = false;
		
		$(".main_img").touchSlider({
			flexible : true,
			speed : 200,
			btn_prev : $("#btn_prev"),
			btn_next : $("#btn_next"),
			paging : $(".point a"),
			counter : function (e){
				$(".point a").removeClass("on").eq(e.current-1).addClass("on");//图片顺序点切换
				$(".img_font span").hide().eq(e.current-1).show();//图片文字切换
			}
		});
		
		$(".main_img").bind("mousedown", function() {
			$dragBln = false;
		});
		
		$(".main_img").bind("dragstart", function() {
			$dragBln = true;
		});
		
		$(".main_img a").click(function(){
			if($dragBln) {
				return false;
			}
		});
		
		timer = setInterval(function(){
			$("#btn_next").click();
		}, 5000);
		
		$(".img_gallery").hover(function(){
			clearInterval(timer);
		},function(){
			timer = setInterval(function(){
				$("#btn_next").click();
			},5000);
		});
		
		$(".main_img").bind("touchstart",function(){
			clearInterval(timer);
		}).bind("touchend", function(){
			timer = setInterval(function(){
				$("#btn_next").click();
			}, 5000);
		});
    </script>
</body>
</html>